For input 0x00000004, the value of "*ecx" has been overwritten by the
cpuid() in hvm_cpuid(), causing a bad value passed to cpuid_count().
Signed-off-by: Dexuan Cui <dexuan.cui@intel.com>
unsigned int *ecx, unsigned int *edx)
{
unsigned int input = *eax;
+ unsigned int count = *ecx;
#ifdef VMXASSIST
if ( input == 0x40000003 )
break;
case 0x00000004:
- cpuid_count(input, *ecx, eax, ebx, ecx, edx);
+ cpuid_count(input, count, eax, ebx, ecx, edx);
*eax &= NUM_CORES_RESET_MASK;
break;